import request from '@/utils/request'
import { baseUrl } from '@/config/env';

//获取数据分析概况
export const getGeneral = (beginDate, endDate) => {
  return request({
    url: baseUrl+'/rest/article/data-general',
    method: 'get',
    params: {
      beginDate,
      endDate,
    }
  })
}

//数据详情（按天,图标)
export const detailChart = (beginDate, endDate) => {
  return request({
    url: baseUrl+'/rest/article/day-general',
    method: 'get',
    params: {
      beginDate,
      endDate,
    }
  })
}

//数据详情（按天,图表)
export const detailTable = (page,limit,beginDate, endDate) => {
  return request({
    url: baseUrl+'/rest/article/day-general-page',
    method: 'get',
    params: {
      page,
      limit,
      beginDate,
      endDate,
    }
  })
}

//图文分析
export const graphicTable = (page,limit,beginDate, endDate) => {
  return request({
    url: baseUrl+'/rest/article/analysis',
    method: 'get',
    params: {
      page,
      limit,
      beginDate,
      endDate,
    }
  })
}